Ver código fonte

init 20220715

lifuquan 2 anos atrás
commit
52bc230329

+ 2 - 0
.gitignore

@@ -0,0 +1,2 @@
+target/
+.vscode/

+ 57 - 0
pom.xml

@@ -0,0 +1,57 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+    <modelVersion>4.0.0</modelVersion>
+
+    <groupId>com.nokia</groupId>
+    <artifactId>sgip_sms_server</artifactId>
+    <version>1.0</version>
+
+    <parent>
+        <groupId>com.nokia</groupId>
+        <artifactId>hb_springboot_parent</artifactId>
+        <version>1.0</version>
+        <relativePath />
+    </parent>
+
+    <properties>
+        <skipTests>true</skipTests>
+    </properties>
+
+    <dependencies>
+        <dependency>
+            <groupId>org.postgresql</groupId>
+            <artifactId>postgresql</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.springframework.boot</groupId>
+            <artifactId>spring-boot-starter-web</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.springframework.boot</groupId>
+            <artifactId>spring-boot-starter-test</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.projectlombok</groupId>
+            <artifactId>lombok</artifactId>
+            <scope>provided</scope>
+        </dependency>
+    </dependencies>
+    <build>
+        <finalName>sms_server</finalName>
+        <plugins>
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-compiler-plugin</artifactId>
+                <configuration>
+                    <source>1.8</source>
+                    <target>1.8</target>
+                </configuration>
+            </plugin>
+            <plugin>
+                <groupId>org.springframework.boot</groupId>
+                <artifactId>spring-boot-maven-plugin</artifactId>
+            </plugin>
+        </plugins>
+    </build>
+</project>

+ 3 - 0
readme.md

@@ -0,0 +1,3 @@
+# sgip_sms_server 短信网关
+
+[短信网关接口说明](%E7%9F%AD%E4%BF%A1%E7%BD%91%E5%85%B3%E6%8E%A5%E5%8F%A3%E8%AF%B4%E6%98%8E.md)

+ 11 - 0
src/main/java/com/nokia/sms/SmsServerApplication.java

@@ -0,0 +1,11 @@
+package com.nokia.sms;
+
+import org.springframework.boot.SpringApplication;
+import org.springframework.boot.autoconfigure.SpringBootApplication;
+
+@SpringBootApplication
+public class SmsServerApplication {
+    public static void main(String[] args) {
+        SpringApplication.run(SmsServerApplication.class, args);
+    }
+}

+ 1 - 0
src/main/resources/application.properties

@@ -0,0 +1 @@
+server.port=12080

+ 28 - 0
短信网关接口说明.md

@@ -0,0 +1,28 @@
+# 短信网关接口说明
+
+入参说明:
+fromSystem  来源系统,按照约定传固定值 如 tousuliucheng
+phone 手机号
+message  短信内容文本
+messageType  各系统自行定义的消息类型,仅用于记录
+
+```http
+http://192.168.70.125:12080/api/sms/send
+Content-Type: application/json
+
+{
+  "fromSystem": "tousuliucheng",
+  "phone": "13231899751",
+  "message": "这是一条短信",
+  "messageType": "催单"
+}
+```
+
+```json
+{
+    "code": 200,
+    "success": true,
+    "message": "成功"
+}
+```
+